package com.workflow.workflowproject.service;

import com.mybatisflex.core.service.IService;
import com.workflow.workflowproject.entity.FlowForm;
import com.workflow.workflowproject.tools.Result.Result;
import jakarta.websocket.server.PathParam;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;

public interface FlowFormService extends IService<FlowForm> {
    /**
     * 添加流程表单版本信息
     *
     * @param
     * @return
     */
    Result addFlowForm(FlowForm flowForm) throws Exception;
    /**
     * 修改流程表单版本信息
     *
     * @param
     * @return
     */
    Result updateFlowForm(String id,Integer type,FlowForm flowForm) throws Exception;
    /**
     * 通过id查询流程表单版本
     *
     * @param
     * @return
     */
    Result getFlowFormById(Long id) throws Exception;
    /**
     * 通过流程信息id查询流程表单版本
     *
     * @param
     * @return
     */
    Result getFlowFormByFlowInfoId(Integer flowInfoId) throws Exception;
    /**
     * 通过流程信息id查询上线的表单
     *
     * @param
     * @return
     */
    Result processOnlineForm(Integer flowInfoId) throws Exception;
    /**
     * 通过lowflow查询字段
     *
     * @param
     * @return
     */
    Result getFlowFieldByFlowInfoId(String flowFormId) throws Exception;
    /**
     * 流程上线
     *
     * @param
     * @return
     */
    Result processOnline(FlowForm flowForm) throws Exception;
    /**
     * 下线流程
     *
     * @param
     * @return
     */
    Result offlineProcess(FlowForm flowForm) throws Exception;
}
